This part is the most basic part as it does not contain any intrinsic content. This part simply displays the part's name as a text string. This part is used as the base code for all the sample code parts, and it implements the following features of OpenDoc:
- System Object Model™ (SOM) wrapper / C++ implementation
- lazy display frames handling
- drawing in 4 standard view types
- part persistency
- basic event handling
- multiple display frames/windows
SamplePart C
This part has the same functionality and features as SamplePart, except it is written as a SOM class in C.
Cappuccino
This part is a simple editor designed to be a "starting point" for leaf part development. This part implements a very a basic content model (i.e., a pascal string) and implements the majority of OpenDoc features a leaf part might want to provide. This part implements the following features of OpenDoc:
- SOM wrapper / C++ implementation
- lazy display frames handling
- drawing in 4 standard view types
- part persistency
- basic event handling
- multiple display frames/windows
- clipboard operations
- drag and drop
- undo
- translation (with or without Paste As dialog)
- promises (used for interchange)
- handling of part menus
- settings dialog and extension
- dialogs
- zoom rects when opening/closing
- scripting (ODSemantic extension subclass)
- being embedded in a link source or destination
- old file/data type nmap resource
- multiple kind support
Picture Viewer
PictureViewer allows users to drop arbitrary PICT data into OpenDoc™ documents. Pictures may be cropped or scaled to the frame, the default mode being cropped. As this part is a “viewer”, content is not editable, nor is it saved within the PictureViewer root document. PictureViewer as the root part does nothing (as a viewer should).
In addition to the features listed in SamplePart, this part implements the following OpenDoc features:
- SOM class implementation
- limited clipboard support, including promises
- viewer implementation
- handling of part menus
- viewer nmap and old file/data type nmap resources
Sound Editor
The SoundEditor part allows users to record, playback, save, and re-record sounds from the current audio input device. It supports data stored in Mac SND format.
- SOM wrapper / C++ implementation
- clipboard support
- idle event handling
- handling of part menus
- settings dialog and extension
- old file/data type nmap resource
- dialogs
- scripting (ODSemantic extension subclass)
- balloon help
Text Editor
Based on Textension, this part is similar to SimpleText. It supports Mac TEXT data as well as native data formats. In addition to the features mentioned above in SamplePart, this part implements the following:
- SOM class implementation
- handling of part menus
- drag and drop
- scrolling (when root of document)
- international TSM support
- preferences file
- settings and preferences dialogs
- supports Semantic Interface to handle TSM Apple events
- multiple kind support
- support for ScriptRunner
DrawEditor
This part is based on Quickdraw and provides tools for creating and editing shapes. Beyond the SamplePart features, this part implements:
- SOM wrapper / C++ implementation
- handling of part menus
- drag and drop
- floating palettes
- embedding
- storage of native and embedded content
- embedded part event handling
- sequenced frames
ScriptRunner
The OSA Plug-In and ScriptRunner part provide OSA scripting capabilities, such as compiling and executing scripts. The TextEditor part supports ScriptRunner, and the ScriptRunner palette is enabled from a menuitem in TextEditor. This part implements the following features:
- SOM class implementation
- floating palettes
- dragging (of result value)
- extensions
- inter-part communication through extensions
- Plug-In
PanelEditor
The Panel Editor is provided as a more simple embedding example. The part allows the user to embed items in a scrolling list and click on the items to change a "panel" display. The interface is similar to many preference dialogs in popular applications. This part implements the following features: